<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title></title>
<link rel="stylesheet" type="text/css" href="../Public/Css/userp.css" />
<script type="text/javascript" src="../Public/Js/jquery.js"></script>
<script type="text/javascript" src="../Public/ckeditor/ckeditor.js"></script>
<script type="text/javascript">
	WINDOW.CKEDITOR_BASEPATH = "/coming/Admin/Public/ckeditor/";
</script>
</head>
<body>
<div class="content">

	<div class="pos">
		<div class="posDe">当前位置 : <font style="color:blue;">产品管理&gt;修改产品信息</font></div>
	</div>
	<div id="proinsert">
		<form action="ProUpdate.php?flag=proupdate" method="POST" enctype="multipart/form-data">
			<fieldset>
			<legend>商品相关信息如下：</legend>
			<table id="inserttable">
				<tr>
				<{*保存food_id*}>
				<td colspan="2"><input type="hidden" name="food_id" value="<{$eachProData.food_id}>" /></td>
				<{*保存原始图片路径*}>
				<td><input type="hidden" name="food_pic" value="<{$eachProData.food_pic}>" /></td>
				<td><input type="hidden" name="food_count" value="<{$eachProData.food_count}>" /></td>
				</tr>
				<tr>
					<td class="textalignright" >商品名称：</td>
					<td width="200px"><input type="TEXT" name="food_name" value="<{$eachProData.food_name}>"/></td>
					<td class="textalignright" width="70px">提&nbsp;供&nbsp;商：</td>
					<{*这个地方从数据库中取出公司的名称*}>
					<td>
						<select name="food_from">
							<{foreach from=$cpData item=v}>
							<option value="<{$v.cp_id}>"><{$v.cp_name}></option>
							<{/foreach}>
						</select>
					</td>

				</tr>
				<tr>
					<td class="textalignright">商品类型：</td>
					<td>
						<select name="food_type">
							<option value="1">节令食品</option>
							<option value="2">四季食品</option>
							<option value="3">儿童食品</option>
						</select>
					</td>
					<td class="textalignright">商品状态：</td>
					<td>
						<SELECT name="food_state">
							<option value="0">正常</option>
							<option value="1">推荐</option>
						</select>
					</td>
				</tr>
				<tr>
					<td class="textalignright">商品单价：</td>
					<td><input type="TEXT" name="food_singleprice"size="7" value="<{$eachProData.food_singleprice}>"/>元</td>
					<td class="textalignright">会员价格：</td>
					<td><input type="text" name="food_userprice" size="7" value="<{$eachProData.food_userprice}>"/>元</td>
				</tr>
				<tr>
					<td class="textalignright">生产日期：</td>
					<td><input type="text" name="year1" size="2" value="<{$eachProData.year1}>"/>年<input type="text" name="month1" size="2" value="<{$eachProData.month1}>"/>月<input type="text" name="day1" size="2" value="<{$eachProData.day1}>"/>日</td>
					<td class="textalignright">过期日期：</td>
					<td><input type="text" name="year2" size="2" value="<{$eachProData.year2}>"/>年<input type="text" name="month2" size="2" value="<{$eachProData.month2}>"/>月<input type="text" name="day2" size="2" value="<{$eachProData.day2}>"/>日</td>
				</tr>
				<tr>
					<td class="textalignright">商品图片：</td>
					<td><img id="imghover" src="<{$eachProData.food_pic}>" alt="<{$eachProData.food_name}>" title="<{$eachProData.food_name}>" /></td>
					<td class="textalignright">重新选择：</td>
					<td><input type='file' name='pic'></td>
				</tr>
				<tr>
					<td class="textalignright">商品介绍：</td>
					<td colspan="3"><TEXTAREA name="food_content"><{$eachProData.food_content}></TEXTAREA></td>
				</tr>
				<tr><td colspan="4"><center><input type="image" src="../Public/Images/confirmSubmit.png"></center></td></tr>
			</table>
			</fieldset>
		</form>
		
	</div>
	<script type="text/javascript">
		CKEDITOR.replace("food_content");
		$("[name='food_from']").val('<{$eachProData.food_from}>');
		$("[name='food_type']").val('<{$eachProData.food_type}>');
		$("[name='food_state']").val('<{$eachProData.food_state}>');
	</script>
</div>
</body>

